package com.ruoyi.jiugongge.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.jiugongge.mapper.JiugonggePrizesMapper;
import com.ruoyi.jiugongge.domain.JiugonggePrizes;
import com.ruoyi.jiugongge.service.IJiugonggePrizesService;
import com.ruoyi.common.support.Convert;

/**
 * 九宫格奖品 服务层实现
 * 
 * @author lzy
 * @date 2019-01-21
 */
@Service
public class JiugonggePrizesServiceImpl implements IJiugonggePrizesService 
{
	@Autowired
	private JiugonggePrizesMapper jiugonggePrizesMapper;

	/**
     * 查询九宫格奖品信息
     * 
     * @param id 九宫格奖品ID
     * @return 九宫格奖品信息
     */
    @Override
	public JiugonggePrizes selectJiugonggePrizesById(String id)
	{
	    return jiugonggePrizesMapper.selectJiugonggePrizesById(id);
	}
	
	/**
     * 查询九宫格奖品列表
     * 
     * @param jiugonggePrizes 九宫格奖品信息
     * @return 九宫格奖品集合
     */
	@Override
	public List<JiugonggePrizes> selectJiugonggePrizesList(JiugonggePrizes jiugonggePrizes)
	{
	    return jiugonggePrizesMapper.selectJiugonggePrizesList(jiugonggePrizes);
	}
	
    /**
     * 新增九宫格奖品
     * 
     * @param jiugonggePrizes 九宫格奖品信息
     * @return 结果
     */
	@Override
	public int insertJiugonggePrizes(JiugonggePrizes jiugonggePrizes)
	{
	    return jiugonggePrizesMapper.insertJiugonggePrizes(jiugonggePrizes);
	}
	
	/**
     * 修改九宫格奖品
     * 
     * @param jiugonggePrizes 九宫格奖品信息
     * @return 结果
     */
	@Override
	public int updateJiugonggePrizes(JiugonggePrizes jiugonggePrizes)
	{
	    return jiugonggePrizesMapper.updateJiugonggePrizes(jiugonggePrizes);
	}

	/**
     * 删除九宫格奖品对象
     * 
     * @param ids 需要删除的数据ID
     * @return 结果
     */
	@Override
	public int deleteJiugonggePrizesByIds(String ids)
	{
		return jiugonggePrizesMapper.deleteJiugonggePrizesByIds(Convert.toStrArray(ids));
	}

	@Override
	public List<JiugonggePrizes> select() {
		// TODO Auto-generated method stub
		return jiugonggePrizesMapper.select();
	}

	@Override
	public List<JiugonggePrizes> queryRemainAwardsByActId(String actId) {
		// TODO Auto-generated method stub
		return jiugonggePrizesMapper.queryRemainAwardsByActId(actId);
	}
	
}
